home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 25
/
Cream of the Crop 25.iso
/
bbs
/
cbb_v10.zip
/
BASEBALL.DOC
next >
Wrap
Text File
|
1997-03-14
|
8KB
|
174 lines
Charlie's Baseball
Written by Charles Crawford.
Documentation.
So here's a baseball door for bulletin boards that I like
since I wrote it and never could really find one that was like
this and would run at the higher BPS rates of today. Here's how
to install it and enjoy! It's free and I take no liability for
anything.
Unzip the contents of CBB-Vxx.zip (where the XX is the
version number) to a subdirectory on your BBS hard disk and then
write the following batch file or something like it. For example
purposes, we are assuming that your BBS drop file is door.sys and
that your bbs subdirectory is c:\pcb and that your game is
located in t:\cbb.
First we need a line that turns off the DOS echo.
@echo off
Now we have to check for the existence of a file called
inuse.flg in the Baseball subdirectory to see if the game is
being played by another caller. If it is, then we will need to
send the batch command to the end of the batch file to run
another program that tells the caller to try later. hence you
will see the goto statement on this line.
if exists t:\cbb\inuse.flg goto end
Now we change to the drive and subdirectory where the game
is.
T:
CD\CBB
Now we create a file called inuse.flg to tell DOS someone
else is using the game so there is no danger of more than one
person in the game and the remote chance that the database would
be in use by more than one person and the second person would be
booted out of the game with an error statement from the
interpreter program DBOLCLIP.exe..
copy x.txt inuse.flg
Now we create the standings text only bulletin called
blt86.prn which is a simple ascii text file with no color codes
to show the caller what the standings are as they enter the game.
basebull
Now we run the game using the BBS drop file of door.sys
which we assume is in c:\pcb where your BBS is. You can use
other drop files that have the full caller name and also caller
first name in them. Most do, but experiment if you like.
Door.sys is very reliable and I use it all the time. If you use
another drop file then put the name of it in the following line
rather than door.sys.
dbolclip cbb.dbx c:\pcb\door.sys
Now we erase the inuse.flg file since you are out of the
game.
del inuse.flg
Next we have to run the bulletin generator that creates
the bulletin file blt86.prn
Basebull
Note if you are running PCBOARD then run CBBBLT.exe instead
of Basebull.exe to get color codes.
Never run cbbblt.exe before the game since you must run
basebull.exe before the game and either cbbblt (if you are
running PCBOARD), or basebull after the game.
Now copy the bulletin file to where you have your bulletins
with the new name of the file you would use for a bulletin.
I use U:\blts as my bulletin subdirectory and the file would
be blt86. and so I do the following.
copy blt86.prn u:\blts\blt86.
Now change back to your bbs subdirectory.
C:
cd\pcb
Now run your back to the BBS command.
Board
Now let's assume that the batch file started and found
t:\cbb\inuse.flg and did not run the game but went to the end of
the batch file. Here we see the :end statement which is a DOS
label to tell the batch file that this is the end of the file if
another condition earlier in the file called the program to run
to the end rather than executing the game.
:end
Now run the little notice program I wrote to tell the person
that they cannot get into the game because someone else is
playing and to come back later, and send the person back to the
BBs...
dbolclip ud.dbx door.sys
Board
The above batch file assumes you have a multi-node system.
At some point I might get into the file locking routines for the
game that would allow multi-node use, but not at this point
You should also know that while the game is free of charge,
the interpreter program called DBOLCLIP.exe will not allow more
than 50 records in the database until the dbonline software is
registered and you get a key file. Unfortunately I do not think
that DBONLINE is still in business and so a key file is probably
not available anymore. So I have coded into the program a
warning for the 49nth person wanting to start a team that the
software has filled up the database, and the program exits
smoothly. It is not likely that you will get more than 20 or 30
players, but who knows eh? In any event, the standings bulletin
generator will delete teams after 30 days of inactivity and so
there should always be room for real baseball fans.
Here's a sample batch file that does not use the restriction
of one person in the game, since either the sysop is running a
single node system or does not worry if there is a conflict and
one caller gets booted out because someone else is using the
database, which is highly unlikely if a couple of players are
accessing the door since most of the action takes place in
memory.
@echo off
t:
cd\cbb
basebull
dbolclip cbb.dbx c:\pcb\door.sys
basebull (or CBBBLT.exe)
copy blt86.prn U:\blts\blt86.
c:
cd\pcb
board
In order to run the ud.dbx notice file to a caller that
someone else is in the game and they should try later, please
copy dbolclip.exe and ud.dbx to your BBS subdirectory where the
drop file is located and the batch file starts running. On my
BBS that is c:\pcb or whichever drive on the network is running
the copy of PCBOARD. For example, I run node 3 on drive x: and
so any doors running off of node three start out from a batch
file in X:\pcb and so ud.dbx and dbolclip.exe are in that
subdirectory and all other \PCB subdirectories on the other
drives R:\pcb for node 1, p:\pcb for node 2 and so forth.
That's it. Let me know what you thing by Writing
Charles.Crawford@mcb-bbs.pn.com for more information. You can
also call eastern time from 9 to 5 (617)-727-5550 extension 4503,
or send netmail to Sysop@1:101/170. Any bug reports would very
much be appreciated and newer versions will come out over time
with more sophisticated play by plays including the commercial
files eluded to in the game. Those commercials will be funny
text files of fake products that should give the caller a laugh.